package com.henu.rescue.mapper;


import com.fasterxml.jackson.annotation.ObjectIdGenerators;
import com.henu.rescue.entity.Organization;
import com.henu.rescue.utils.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface OrgMapper {
    // 测试获取所有org信息
    List<Organization> getAll();

    //分页查询
    List<Organization> selectOrgInfoByPage(Page<Organization> page) ;

    //添加组织
    Integer addOrg(Organization organization);

    //删除组织
    Integer deleteOrg(@Param("orgId")Integer orgId);

    //修改组织信息
    Integer updateOrg(Organization organization);



    int getCountByPage(Page<Organization> page);

    List<Organization> getAllOrg();

    String getNameById(Integer orgId);
}
